package com.juzi.OOP;

public class Test {
    public static void main(String[] args) {
        //创建对象
        //无参构造器创建对象
        Student s = new Student();
        s.setAge(23);
        s.setName("桔子");
        s.setSex('女');
        System.out.println(s.getSex());
        System.out.println(s.getAge());
        System.out.println(s.getName());

        //有参构造器创建对象
        Student s2 = new Student("耳朵",23,'男');
        System.out.println(s2.getSex());
        System.out.println(s2.getAge());
        System.out.println(s2.getName());


    }
}
